<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@page import="dto.FileListDTO"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<script type="text/javascript">
function imagelink(){
	var form = document.form1;
	form.action = "getContentByRoom2.do";
	form.method = "post";
	form.submit();	
	
}

</script>
<div style="background-image: img/bg.jpg">
<form action="selectByDong.do" method="post">
<fieldset>
<legend><b>Search</b></legend>
<select name="search">
	<option value="sido">Search by [City]</option>
	<option value="gugun">Search by [Gu/Gun]</option>
	<option value="dong">Search by [Dong]</option>	
</select>
	<input type="text" width="300" name="dong">
	<input type="submit" value="search">
	</fieldset>
</form>
<c:forEach items="${requestScope.map }" var="entry">
	<c:if test="${entry.key=='room' }"><br>
	<font size="5" style="font-weight: bold;" face="Comic Sans MS">&nbsp;&nbsp;&nbsp;${entry.value} room is available to rent.</font>
	</c:if>
	<c:if test="${entry.key=='member' }"><br>
	<font size="5" style="font-weight: bold;" face="Comic Sans MS">&nbsp;Rent from ${entry.value} people,</font> 
	</c:if>
</c:forEach>

<div id="div1" align="center">
<form name="form1">
<c:forEach items="${requestScope.map }" var="entry">
<c:if test="${entry.key=='fdto' }"><br>
	<br><br><img width="700px" height="500px" src="/Project_homeshare_room/uproomfile/${entry.value.fileName}" onclick="imagelink()" ><br>
	<input type="hidden" name="postScript_roomno" value="${entry.value.fileName}">
	</c:if>
</c:forEach>
</form>
</div>
</html>
